< previous page page_99 next page >

Page 99
Private Sub chkBonus_Click()
cmdSave.Enabled = True
End Sub

Private Sub chkHealth_Click()
cmdSave.Enabled = True
End Sub
analysis.gifOnce again, the Click( ) event of check boxes should enable the Save command buttons Enabled property.

Picture Control Events
The picture control can respond to the graphic changing or the user clicking the picture. The most common event will be the user clicking the picture control.
The Picture_Click( ) Event
In the Employee Information form, you created a picture that displays an envelope graphic. This graphic may be used to send some email to an employee. In the Click() event, you would write code to send that email. Lets simulate that here by writing the following code:
9f31265bb40b592b1929e18a47ab28e5.gif
Private Sub picMail_Click()
   ' Send Email here
   frmEMail.Show
End Sub
Lets create another form, called frmEmail, and use it to fill in the email information (see Figure 5.2). You can call any form from any other form by simply specifying the name of the form followed by a period and then the Show method.
8160-0099a.gif
Figure 5.2
The Email form.

 
< previous page page_99 next page >

If you like this book, buy it!